home *** CD-ROM | disk | FTP | other *** search
- #ifndef LIBRARIES_NEWICON_H
- #define LIBRARIES_NEWICON_H
-
- #ifndef EXEC_LIBRARIES_H
- #include <exec/libraries.h>
- #endif
-
- #ifndef WORKBENCH_WORKBENCH_H
- #include "workbench/workbench.h"
- #endif
-
-
- struct NewIconBase
- {
- struct Library nib_Lib;
- APTR nib_SegList;
- LONG nib_Precision; /* precision when remapping images via */
- /* RemapChunkyImage(). Programs are not supposed */
- /* to modify this, it is a value chosen by the user */
- /* in the preferences. */
- LONG nib_Flags; /* library base flags */
- /* Again, programs are not supposed to modify this. (V38)*/
- LONG nib_DPMode; /* Depth Promotion mode value. (V39) */
- /* Ditto */
- };
-
-
- #define NIFLG_DO_DITHER (1<<0) /* use dithering when exact pen not available */
-
- #define NIFLG_IS_DISABLED (1<<1) /* Commodity is disabled (V39) */
-
- #define NIFLG_RTGMODE (1<<2) /* Use FastRAM when possible instead of CHIP)
- (V39) */
-
- #define NIFLG_NOBORDER (1<<3) /* Won't display any border around icons,
- and will also make them transparent.
- (V39) */
-
- /* Values for nib_DPMode (V39) */
-
- #define NIDPM_NEVER 0 /* Do not depth promote old icons */
- #define NIDPM_WBONLY 1 /* Only promote icons opened by Workbench */
- #define NIDPM_ALL 2 /* Depth promote all old icons opened */
-
- /*
- * This structure contains an image in a format unusual to the Amiga: chunky
- * pixel. We use this format because it is faster to remap to a given palette.
- */
- struct ChunkyImage
- {
- UWORD Width; /* width of the image. Must be <= 93 */
- UWORD Height; /* height of the image. Must be <= 93 */
- UWORD NumColors; /* number of pens defined in the palette. Must be <= 256 */
- UWORD Flags; /* see defines below */
- UBYTE *Palette; /* array of RGB components of the pens (one byte per gun) */
- UBYTE *ChunkyData; /* Width*Height bytes storing the colors of the pixels */
- };
-
- #define CIF_COLOR_0_TRANSP (1<<0) /* color 0 is transparent, not the one */
- /* stored in palette */
-
- #define CIF_DEFAULT (1<<1) /* when this bit is set, the image was */
- /* obtained via the DEFAULTIMAGE ToolType, */
- /* therefore it is not actually part of the */
- /* icon and will not be stored in the */
- /* ToolTypes on a PutNewDiskObject(). */
-
-
-
- struct NewDiskObject
- {
- struct DiskObject *ndo_StdObject; /* The old-style icon */
- struct ChunkyImage *ndo_NormalImage; /* May be NULL, meaning no new style icon */
- struct ChunkyImage *ndo_SelectedImage; /* May be NULL, meaning no secondary image */
- };
-
- #endif /* LIBRARIES_NEWICON_H */
-